<template>
<div>
    <input type="text" @keyup.enter="enterFn">
    <input type="text" @keyup.esc="escFn">
</div>
</template>

<script>
export default {
	data() {
		return {};
	},
    methods: {
        enterFn (){
            console.log(1);
        },
        escFn (){
            console.log(2);
        }
    }
};
</script>

<style scoped>
</style>